<!-- goodsdesc -->
<template>
  <div class="gz-desc">
    <h1 class="gz-dc-title" v-text="desc.title"></h1>
    <hr>
    <p class="gz-dc-content" v-html="desc.content"></p>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        id: this.$route.params.id,
        desc: {}
      }
    },
  
    created() {
      this.getDesc();
    },
  
    methods: {
      getDesc() {
        this.axios.get("api/goods/getdesc/" + this.id).then(resp => {
        if (resp.data.status === 0) {
          // 获取数据成功
          this.desc = resp.data.message[0];
         
        } else {
          // 获取失败
          Toast("获取数据失败");
        }
      });
      }
    },
  
    components: {}
 }
</script>

<style lang='scss'>
  .gz-desc {
    padding: 3px;
    .gz-dc-title {
      min-height: 30px;
      font-size: 16px;
      color: #26afff;
      text-align: center;
      line-height: 30px;
    }
    .gz-dc-content{
      img {
        width: 100%;
      }
    }
  }
</style>